<table class='table table-striped challenge-table text-light'>
  <thead>
    <tr><th class='col-md-4'>Name</th><th class='col-md-1'>Points</th><th
        class='col-md-1'>Solves</th><th
        class='col-md-3'>Actions</th></tr>
  </thead>
  <tbody>
    <tr ng-repeat='challenge in challenges'><td>{{challenge.name}}</td>
      <td>{{challenge.points}}</td>
      <td>{{challenge.solves}}</td>
      <td class='oneline'>
        <!-- replace lockbutton -->
        <a class='btn lockbtn ng-hide btn-warning'
          ng-hide='challenge.unlocked'
          ng-click='lockChallenge(challenge, false)'>Locked</a>
        <a class='btn lockbtn btn-info'
          ng-show='challenge.unlocked'
          ng-click='lockChallenge(challenge, true)'>Unlocked</a>
        <a ng-href='/admin/challenge/{{challenge.cid}}'
          class='btn btn-primary'>Edit</a>
        <a ng-click='deleteChallenge(challenge)'
          class='btn btn-danger'>Delete</a>
        <a ng-click='moveUp(challenge)' ng-disabled='$first'
          class='btn btn-xs'>&#x25b2;</a>
        <a ng-click='moveDown(challenge)' ng-disabled='$last'
          class='btn btn-xs'>&#x25bc;</a>
      </td>
    </tr>
    <tr><td></td><td></td><td></td>
      <td><a ng-click='newChallenge()'
          class='btn btn-primary'>New</a><a ng-click='saveBulk()'
          ng-enabled='weightsChanged' class='btn btn-info'
          >Save Order</a></td></tr>
  </tbody>
</table>
